package com.baosight.risk.service.quartz.impl;

import com.baosight.risk.api.quartz.ISysSyncEmpleeService;
import com.baosight.risk.mapper.quartz.SysSyncEmpleeMapper;
import com.baosight.risk.service.quartz.entity.SyncEmpleeEntitiy;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author CuiShihao
 * <p>
 * 定时任务 同步人员实现
 */
@Service
public class SysSyncEmpleeServiceImpl implements ISysSyncEmpleeService {

    @Autowired
    private SysSyncEmpleeMapper sysSyncEmpleeMapper;

    @Override
    public void batchInsertUserList(List<SyncEmpleeEntitiy> userList) {
        sysSyncEmpleeMapper.batchInsertUserList(userList);
    }

    @Override
    public List<SyncEmpleeEntitiy> getEmpleeFromOtherDB(SyncEmpleeEntitiy syncEmpleeEntitiy) {
        List<SyncEmpleeEntitiy> result = sysSyncEmpleeMapper.getEmpleeFromOtherDB(syncEmpleeEntitiy);
        return result;
    }

    @Override
    public List<SyncEmpleeEntitiy> getEmpleeListFromOtherDB(String compCode) {
        return sysSyncEmpleeMapper.getEmpleeListFromOtherDB(compCode);
    }
}
